Platform Explorer / Nuxeo Platform 5.8

Contribution org.nuxeo.ecm.social.user.relationship.layout--widgets

This contribution is part of XML component org.nuxeo.ecm.social.user.relationship.layout inside nuxeo-user-relationship-5.8.jar

Extension Point

Extension point widgets of component WebLayoutManager.

Contributed Items

  • <widget name="summary_user_relationship" type="summary_user_relationship"/>
  • <widget name="user_relationship_add" type="manage_user_relations">
          <fields>
            <field/>
          </fields>
        </widget>
  • <widget name="listing_user_relationship_add" type="manage_user_relations">
          <fields>
            <field>data</field>
          </fields>
          <properties mode="any">
            <property name="panelIdsToBeReRendered">usersListingRelationshipPanel,userNetworkPanel</property>
          </properties>
        </widget>
  • <widget name="user_relationship_contacts" type="template">
          <labels>
            <label mode="any">label.social.user.widget.relationships</label>
          </labels>
          <translated>true</translated>
          <fields>
            <field/>
          </fields>
          <properties mode="any">
            <property name="template">/widgets/user_relationship_contacts_widget_template.xhtml</property>
          </properties>
          <widgetModes>
            <mode value="any">view</mode>
          </widgetModes>
        </widget>
  • <widget name="user_relationship_relations" type="template">
          <fields>
            <field>data</field>
          </fields>
          <properties mode="any">
            <property name="template">/widgets/user_relationship_relation_with_user.xhtml</property>
          </properties>
          <widgetModes>
            <mode value="any">view</mode>
          </widgetModes>
        </widget>
  • <widget name="user_relationship_username" type="template">
          <fields>
            <field>data</field>
          </fields>
          <properties mode="any">
            <property name="template">/widgets/user_relationship_profile_username_widget_template.xhtml</property>
          </properties>
          <widgetModes>
            <mode value="any">view</mode>
          </widgetModes>
        </widget>
  • <widget name="user_relationship_avatar" type="avatar">
          <labels>
            <label mode="any">label.userprofile.avatar</label>
          </labels>
          <translated>true</translated>
          <helpLabels>
            <label mode="edit">
              helplabel.userprofile.avatar
            </label>
          </helpLabels>
          <fields>
            <field>data</field>
          </fields>
          <properties mode="any">
            <property name="file_property_name">userprofile:avatar</property>
          </properties>
        </widget>
  • <widget name="avatar" type="avatar">
          <labels>
            <label mode="any">label.userprofile.avatar</label>
          </labels>
          <translated>true</translated>
          <helpLabels>
            <label mode="edit">
              helplabel.userprofile.avatar
            </label>
          </helpLabels>
          <fields>
            <field/>
            <field>userprofile:avatar</field>
          </fields>
          <properties mode="any">
            <property name="file_property_name">userprofile:avatar</property>
          </properties>
          <widgetModes>
            <mode value="view">#{userRelationshipActions.canViewProfile(layoutValue) ? 'view' : 'hidden'}</mode>
          </widgetModes>
        </widget>
  • <widget name="birthdate" type="datetime">
          <labels>
            <label mode="any">label.userprofile.birthdate</label>
          </labels>
          <translated>true</translated>
          <helpLabels>
            <label mode="edit">
              helplabel.userprofile.birthdate
            </label>
          </helpLabels>
          <fields>
            <field>userprofile:birthdate</field>
          </fields>
          <properties widgetMode="any">
            <property name="pattern">#{nxu:basicDateFormater()}</property>
          </properties>
          <properties widgetMode="edit">
            <property name="format">#{nxu:basicDateFormater()}</property>
          </properties>
          <widgetModes>
            <mode value="view">#{userRelationshipActions.canViewProfile(layoutValue) ? 'view' : 'hidden'}</mode>
          </widgetModes>
        </widget>
  • <widget name="phonenumber" type="text">
          <labels>
            <label mode="any">label.userprofile.phonenumber</label>
          </labels>
          <translated>true</translated>
          <fields>
            <field>userprofile:phonenumber</field>
          </fields>
          <properties widgetMode="edit">
            <property name="styleClass">dataInputText</property>
          </properties>
          <widgetModes>
            <mode value="view">#{userRelationshipActions.canViewProfile(layoutValue) ? 'view' : 'hidden'}</mode>
          </widgetModes>
        </widget>
  • <widget name="gender" type="template">
          <labels>
            <label mode="any">label.userprofile.gender</label>
          </labels>
          <translated>true</translated>
          <fields>
            <field>userprofile:gender</field>
          </fields>
          <properties mode="any">
            <property name="template">/widgets/gender_widget_template.xhtml
            </property>
          </properties>
          <widgetModes>
            <mode value="view">#{userRelationshipActions.canViewProfile(layoutValue) ? 'view' : 'hidden'}</mode>
          </widgetModes>
        </widget>
  • <widget name="publicprofile" type="checkbox">
          <labels>
            <label mode="any">label.socialprofile.publicprofile</label>
          </labels>
          <translated>true</translated>
          <fields>
            <field>socialprofile:publicprofile</field>
          </fields>
          <properties widgetMode="edit">
            <property name="styleClass">dataInputText</property>
          </properties>
           <widgetModes>
            <mode value="view">#{userRelationshipActions.canViewProfile(layoutValue) ? 'view' : 'hidden'}</mode>
          </widgetModes>
        </widget>

XML Source

<extension point="widgets" target="org.nuxeo.ecm.platform.forms.layout.WebLayoutManager">

    <widget name="summary_user_relationship" type="summary_user_relationship"/>

    <widget name="user_relationship_add" type="manage_user_relations">
      <fields>
        <field/>
      </fields>
    </widget>

    <widget name="listing_user_relationship_add" type="manage_user_relations">
      <fields>
        <field>data</field>
      </fields>
      <properties mode="any">
        <property name="panelIdsToBeReRendered">usersListingRelationshipPanel,userNetworkPanel</property>
      </properties>
    </widget>

    <widget name="user_relationship_contacts" type="template">
      <labels>
        <label mode="any">label.social.user.widget.relationships</label>
      </labels>
      <translated>true</translated>
      <fields>
        <field/>
      </fields>
      <properties mode="any">
        <property name="template">/widgets/user_relationship_contacts_widget_template.xhtml</property>
      </properties>
      <widgetModes>
        <mode value="any">view</mode>
      </widgetModes>
    </widget>

    <widget name="user_relationship_relations" type="template">
      <fields>
        <field>data</field>
      </fields>
      <properties mode="any">
        <property name="template">/widgets/user_relationship_relation_with_user.xhtml</property>
      </properties>
      <widgetModes>
        <mode value="any">view</mode>
      </widgetModes>
    </widget>

    <widget name="user_relationship_username" type="template">
      <fields>
        <field>data</field>
      </fields>
      <properties mode="any">
        <property name="template">/widgets/user_relationship_profile_username_widget_template.xhtml</property>
      </properties>
      <widgetModes>
        <mode value="any">view</mode>
      </widgetModes>
    </widget>

    <widget name="user_relationship_avatar" type="avatar">
      <labels>
        <label mode="any">label.userprofile.avatar</label>
      </labels>
      <translated>true</translated>
      <helpLabels>
        <label mode="edit">
          helplabel.userprofile.avatar
        </label>
      </helpLabels>
      <fields>
        <field>data</field>
      </fields>
      <properties mode="any">
        <property name="file_property_name">userprofile:avatar</property>
      </properties>
    </widget>

    <!-- override to manage public/private profile -->
    <widget name="avatar" type="avatar">
      <labels>
        <label mode="any">label.userprofile.avatar</label>
      </labels>
      <translated>true</translated>
      <helpLabels>
        <label mode="edit">
          helplabel.userprofile.avatar
        </label>
      </helpLabels>
      <fields>
        <field/>
        <field>userprofile:avatar</field>
      </fields>
      <properties mode="any">
        <property name="file_property_name">userprofile:avatar</property>
      </properties>
      <widgetModes>
        <mode value="view">#{userRelationshipActions.canViewProfile(layoutValue) ? 'view' : 'hidden'}</mode>
      </widgetModes>
    </widget>

    <!-- override to manage public/private profile -->
    <widget name="birthdate" type="datetime">
      <labels>
        <label mode="any">label.userprofile.birthdate</label>
      </labels>
      <translated>true</translated>
      <helpLabels>
        <label mode="edit">
          helplabel.userprofile.birthdate
        </label>
      </helpLabels>
      <fields>
        <field>userprofile:birthdate</field>
      </fields>
      <properties widgetMode="any">
        <property name="pattern">#{nxu:basicDateFormater()}</property>
      </properties>
      <properties widgetMode="edit">
        <property name="format">#{nxu:basicDateFormater()}</property>
      </properties>
      <widgetModes>
        <mode value="view">#{userRelationshipActions.canViewProfile(layoutValue) ? 'view' : 'hidden'}</mode>
      </widgetModes>
    </widget>

    <!-- override to manage public/private profile -->
    <widget name="phonenumber" type="text">
      <labels>
        <label mode="any">label.userprofile.phonenumber</label>
      </labels>
      <translated>true</translated>
      <fields>
        <field>userprofile:phonenumber</field>
      </fields>
      <properties widgetMode="edit">
        <property name="styleClass">dataInputText</property>
      </properties>
      <widgetModes>
        <mode value="view">#{userRelationshipActions.canViewProfile(layoutValue) ? 'view' : 'hidden'}</mode>
      </widgetModes>
    </widget>

    <!-- override to manage public/private profile -->
    <widget name="gender" type="template">
      <labels>
        <label mode="any">label.userprofile.gender</label>
      </labels>
      <translated>true</translated>
      <fields>
        <field>userprofile:gender</field>
      </fields>
      <properties mode="any">
        <property name="template">/widgets/gender_widget_template.xhtml
        </property>
      </properties>
      <widgetModes>
        <mode value="view">#{userRelationshipActions.canViewProfile(layoutValue) ? 'view' : 'hidden'}</mode>
      </widgetModes>
    </widget>

    <widget name="publicprofile" type="checkbox">
      <labels>
        <label mode="any">label.socialprofile.publicprofile</label>
      </labels>
      <translated>true</translated>
      <fields>
        <field>socialprofile:publicprofile</field>
      </fields>
      <properties widgetMode="edit">
        <property name="styleClass">dataInputText</property>
      </properties>
       <widgetModes>
        <mode value="view">#{userRelationshipActions.canViewProfile(layoutValue) ? 'view' : 'hidden'}</mode>
      </widgetModes>
    </widget>
  </extension>